/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package VIEW;

import BEANS.ComboItem;
import CONTROLLERS.CartController;
import UTIL.InputValidator;
import java.awt.event.KeyEvent;
import javax.swing.JComboBox;
import javax.swing.JTable;


/**
 *
 * @author Belthazod
 */
public class InventoryUI extends javax.swing.JPanel{
    static CartController cartController;
    CriticalProducts criticalProducts;
    ReportsSales reportsSales;
    /**
     * Creates new form InventoryUI
     */
    public InventoryUI() {
        try{
        initComponents();
        salesDateChooser.setFormat(0);
        dateTo.setFormat(0);
        dateFrom.setFormat(0);
        quantityInputDialog.setLocationRelativeTo(null);
        inputSerialDialog.setLocationRelativeTo(null);
        salesHistoryDialog.setLocationRelativeTo(null);
        editSerialDialog.setLocationRelativeTo(null);
        editQuantityDialog.setLocationRelativeTo(null);
        inputWire.setLocationRelativeTo(null);
        inventoryTable.getColumnModel().getColumn(0).setMaxWidth(0);
        inventoryTable.getColumnModel().getColumn(0).setMinWidth(0);
        inventoryTable.getColumnModel().getColumn(0).setPreferredWidth(0);
        
        inventoryTable.getColumnModel().getColumn(1).setMaxWidth(0);
        inventoryTable.getColumnModel().getColumn(1).setMinWidth(0);
        inventoryTable.getColumnModel().getColumn(1).setPreferredWidth(0);
        
        inventoryTable.getColumnModel().getColumn(5).setMaxWidth(0);
        inventoryTable.getColumnModel().getColumn(5).setMinWidth(0);
        inventoryTable.getColumnModel().getColumn(5).setPreferredWidth(0);
        
        cartTable.getColumnModel().getColumn(0).setMaxWidth(0);
        cartTable.getColumnModel().getColumn(0).setMinWidth(0);
        cartTable.getColumnModel().getColumn(0).setPreferredWidth(0);
        
        cartTable.getColumnModel().getColumn(1).setMaxWidth(0);
        cartTable.getColumnModel().getColumn(1).setMinWidth(0);
        cartTable.getColumnModel().getColumn(1).setPreferredWidth(0);
        
        cartController = new CartController(productFilterCategoryComboBox, cartTable, 
                inventoryTable, inventoryTableSearchInput, 
                clear, salesTypeDialog, salesDateChooser, 
                receiptNumberInput, productFilterSupplierComboBox, 
                quantityInputDialog, inputSerialDialog, 
                inputQuantityTextField, inputSerialTextField, 
                editQuantity, editSerialInput, 
                editQuantityDialog, editSerialDialog, receiptNos, remarksInput, 
                salesHistoryTable, dateTo, dateFrom, input, inputLength, inputWire, whole, partial);
        cartController.justDClickIt(inventoryTable);
        cartController.justDClickIt2(cartTable);
        //cartController.justDClickItToDelete(cartTable);
        this.criticalProducts = new CriticalProducts();
        this.reportsSales = new ReportsSales();
        InputValidator.enabler(inventoryTable, jButton14); 
        InputValidator.enabler(cartTable, removeFromListButton);
        InputValidator.enabler(cartTable, editButton);
        salesDateChooser.setFormat(0);
//        cartController.ColorStatus();
        input.setLocationRelativeTo(null);
        }catch(Exception e){
            
        }
    }

    /**
     * This method is called from within the constructor to initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is always
     * regenerated by the Form Editor.
     */
    @SuppressWarnings("unchecked")
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        salesTypeDialog = new javax.swing.JDialog();
        selectPurchaseButton = new javax.swing.JButton();
        selectServiceButton = new javax.swing.JButton();
        cancelButton = new javax.swing.JButton();
        receiptInfoLabel1 = new javax.swing.JLabel();
        receiptInfoLabel2 = new javax.swing.JLabel();
        quantityInputDialog = new javax.swing.JDialog();
        jLabel6 = new javax.swing.JLabel();
        inputQuantityTextField = new javax.swing.JTextField();
        quantityInputButton = new javax.swing.JButton();
        quantityCancelButton = new javax.swing.JButton();
        inputSerialDialog = new javax.swing.JDialog();
        inputSerialTextField = new javax.swing.JTextField();
        serialInputButton = new javax.swing.JButton();
        serialCancelButton = new javax.swing.JButton();
        jLabel8 = new javax.swing.JLabel();
        jLabel13 = new javax.swing.JLabel();
        editQuantityDialog = new javax.swing.JDialog();
        editQuantityOK = new javax.swing.JButton();
        editQuantityCancel = new javax.swing.JButton();
        jLabel9 = new javax.swing.JLabel();
        editQuantity = new javax.swing.JTextField();
        editSerialDialog = new javax.swing.JDialog();
        editSerialInput = new javax.swing.JTextField();
        editSerial = new javax.swing.JButton();
        cancelEditSerial = new javax.swing.JButton();
        jLabel10 = new javax.swing.JLabel();
        ReceiptNumber = new javax.swing.JDialog();
        receiptNumberInput = new javax.swing.JTextField();
        jLabel11 = new javax.swing.JLabel();
        jButton3 = new javax.swing.JButton();
        jButton4 = new javax.swing.JButton();
        salesHistoryDialog = new javax.swing.JDialog();
        jScrollPane2 = new javax.swing.JScrollPane();
        salesHistoryTable = new javax.swing.JTable();
        jLabel15 = new javax.swing.JLabel();
        jLabel16 = new javax.swing.JLabel();
        jLabel17 = new javax.swing.JLabel();
        dateTo = new datechooser.beans.DateChooserCombo();
        dateFrom = new datechooser.beans.DateChooserCombo();
        input = new javax.swing.JDialog();
        jLabel18 = new javax.swing.JLabel();
        inputLength = new javax.swing.JTextField();
        jButton6 = new javax.swing.JButton();
        jButton7 = new javax.swing.JButton();
        inputWire = new javax.swing.JDialog();
        whole = new javax.swing.JRadioButton();
        partial = new javax.swing.JRadioButton();
        jButton8 = new javax.swing.JButton();
        jButton9 = new javax.swing.JButton();
        clear = new javax.swing.JLabel();
        jScrollPane3 = new javax.swing.JScrollPane();
        inventoryTable = new javax.swing.JTable();
        jButton14 = new javax.swing.JButton();
        jButton20 = new javax.swing.JButton();
        jLabel2 = new javax.swing.JLabel();
        jButton1 = new javax.swing.JButton();
        inventoryTableSearchInput = new javax.swing.JTextField();
        jScrollPane4 = new javax.swing.JScrollPane();
        cartTable = new javax.swing.JTable();
        jButton2 = new javax.swing.JButton();
        jLabel1 = new javax.swing.JLabel();
        jLabel3 = new javax.swing.JLabel();
        removeFromListButton = new javax.swing.JButton();
        productFilterCategoryComboBox = new javax.swing.JComboBox<ComboItem>();
        jLabel7 = new javax.swing.JLabel();
        jLabel5 = new javax.swing.JLabel();
        productFilterSupplierComboBox = new javax.swing.JComboBox<ComboItem>();
        editButton = new javax.swing.JButton();
        salesDateChooser = new datechooser.beans.DateChooserCombo();
        clearTableButton = new javax.swing.JButton();
        jLabel4 = new javax.swing.JLabel();
        receiptNos = new javax.swing.JTextField();
        jLabel12 = new javax.swing.JLabel();
        jScrollPane1 = new javax.swing.JScrollPane();
        remarksInput = new javax.swing.JTextArea();
        jSeparator1 = new javax.swing.JSeparator();
        jButton5 = new javax.swing.JButton();
        jLabel14 = new javax.swing.JLabel();

        salesTypeDialog.setTitle("Choose Transaction Type");
        salesTypeDialog.setBounds(new java.awt.Rectangle(0, 0, 500, 200));
        salesTypeDialog.setCursor(new java.awt.Cursor(java.awt.Cursor.DEFAULT_CURSOR));
        salesTypeDialog.setModalityType(java.awt.Dialog.ModalityType.APPLICATION_MODAL);
        salesTypeDialog.setLocationRelativeTo(null);

        selectPurchaseButton.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        selectPurchaseButton.setText("Purchase");
        selectPurchaseButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                selectPurchaseButtonActionPerformed(evt);
            }
        });

        selectServiceButton.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        selectServiceButton.setText("Service");
        selectServiceButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                selectServiceButtonActionPerformed(evt);
            }
        });

        cancelButton.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        cancelButton.setText("Cancel");
        cancelButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                cancelButtonActionPerformed(evt);
            }
        });

        receiptInfoLabel1.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        receiptInfoLabel1.setText("The system has detected an item with warranty among the products in the cart.");
        receiptInfoLabel1.setVisible(false);

        receiptInfoLabel2.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        receiptInfoLabel2.setText("Please enter the Receipt Number:");
        receiptInfoLabel2.setVisible(false);

        javax.swing.GroupLayout salesTypeDialogLayout = new javax.swing.GroupLayout(salesTypeDialog.getContentPane());
        salesTypeDialog.getContentPane().setLayout(salesTypeDialogLayout);
        salesTypeDialogLayout.setHorizontalGroup(
            salesTypeDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(salesTypeDialogLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(salesTypeDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, salesTypeDialogLayout.createSequentialGroup()
                        .addGap(0, 0, Short.MAX_VALUE)
                        .addComponent(cancelButton))
                    .addGroup(salesTypeDialogLayout.createSequentialGroup()
                        .addGroup(salesTypeDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                            .addComponent(receiptInfoLabel1)
                            .addGroup(salesTypeDialogLayout.createSequentialGroup()
                                .addGroup(salesTypeDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                                    .addComponent(selectPurchaseButton, javax.swing.GroupLayout.PREFERRED_SIZE, 103, javax.swing.GroupLayout.PREFERRED_SIZE)
                                    .addComponent(receiptInfoLabel2))
                                .addGap(35, 35, 35)
                                .addComponent(selectServiceButton, javax.swing.GroupLayout.PREFERRED_SIZE, 111, javax.swing.GroupLayout.PREFERRED_SIZE)))
                        .addGap(0, 0, Short.MAX_VALUE)))
                .addContainerGap())
        );
        salesTypeDialogLayout.setVerticalGroup(
            salesTypeDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, salesTypeDialogLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(receiptInfoLabel1, javax.swing.GroupLayout.PREFERRED_SIZE, 14, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(receiptInfoLabel2)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addGroup(salesTypeDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(selectServiceButton, javax.swing.GroupLayout.PREFERRED_SIZE, 44, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(selectPurchaseButton, javax.swing.GroupLayout.PREFERRED_SIZE, 44, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(cancelButton)
                .addContainerGap())
        );

        quantityInputDialog.setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        quantityInputDialog.setTitle("Input Product Quantity");
        quantityInputDialog.setBounds(new java.awt.Rectangle(0, 0, 250, 130));
        quantityInputDialog.setModalityType(java.awt.Dialog.ModalityType.APPLICATION_MODAL);
        quantityInputDialog.addWindowListener(new java.awt.event.WindowAdapter() {
            public void windowClosed(java.awt.event.WindowEvent evt) {
                quantityInputDialogWindowClosed(evt);
            }
        });

        jLabel6.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jLabel6.setText("Enter quantity:");

        inputQuantityTextField.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        inputQuantityTextField.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                inputQuantityTextFieldActionPerformed(evt);
            }
        });
        inputQuantityTextField.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyPressed(java.awt.event.KeyEvent evt) {
                inputQuantityTextFieldKeyPressed(evt);
            }
        });

        quantityInputButton.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        quantityInputButton.setText("OK");
        quantityInputButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                quantityInputButtonActionPerformed(evt);
            }
        });

        quantityCancelButton.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        quantityCancelButton.setText("Cancel");
        quantityCancelButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                quantityCancelButtonActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout quantityInputDialogLayout = new javax.swing.GroupLayout(quantityInputDialog.getContentPane());
        quantityInputDialog.getContentPane().setLayout(quantityInputDialogLayout);
        quantityInputDialogLayout.setHorizontalGroup(
            quantityInputDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(quantityInputDialogLayout.createSequentialGroup()
                .addGap(29, 29, 29)
                .addGroup(quantityInputDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(quantityInputDialogLayout.createSequentialGroup()
                        .addComponent(jLabel6)
                        .addGap(18, 18, 18)
                        .addComponent(inputQuantityTextField, javax.swing.GroupLayout.PREFERRED_SIZE, 54, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, quantityInputDialogLayout.createSequentialGroup()
                        .addComponent(quantityInputButton, javax.swing.GroupLayout.PREFERRED_SIZE, 55, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(quantityCancelButton)))
                .addContainerGap(21, Short.MAX_VALUE))
        );
        quantityInputDialogLayout.setVerticalGroup(
            quantityInputDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(quantityInputDialogLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(quantityInputDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel6)
                    .addComponent(inputQuantityTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 30, Short.MAX_VALUE)
                .addGroup(quantityInputDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(quantityInputButton)
                    .addComponent(quantityCancelButton))
                .addContainerGap())
        );

        inputSerialDialog.setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        inputSerialDialog.setTitle("Input Product Serial Number");
        inputSerialDialog.setBounds(new java.awt.Rectangle(0, 0, 450, 160));
        inputSerialDialog.setModalityType(java.awt.Dialog.ModalityType.APPLICATION_MODAL);
        inputSerialDialog.addWindowListener(new java.awt.event.WindowAdapter() {
            public void windowClosed(java.awt.event.WindowEvent evt) {
                inputSerialDialogWindowClosed(evt);
            }
        });

        inputSerialTextField.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        inputSerialTextField.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                inputSerialTextFieldActionPerformed(evt);
            }
        });
        inputSerialTextField.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyPressed(java.awt.event.KeyEvent evt) {
                inputSerialTextFieldKeyPressed(evt);
            }
        });

        serialInputButton.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        serialInputButton.setText("OK");
        serialInputButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                serialInputButtonActionPerformed(evt);
            }
        });

        serialCancelButton.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        serialCancelButton.setText("Cancel");
        serialCancelButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                serialCancelButtonActionPerformed(evt);
            }
        });

        jLabel8.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jLabel8.setText("Please Enter serial number:");

        jLabel13.setText("This item currently has warranty. ");

        javax.swing.GroupLayout inputSerialDialogLayout = new javax.swing.GroupLayout(inputSerialDialog.getContentPane());
        inputSerialDialog.getContentPane().setLayout(inputSerialDialogLayout);
        inputSerialDialogLayout.setHorizontalGroup(
            inputSerialDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, inputSerialDialogLayout.createSequentialGroup()
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addGroup(inputSerialDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel13)
                    .addGroup(inputSerialDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, inputSerialDialogLayout.createSequentialGroup()
                            .addComponent(serialInputButton, javax.swing.GroupLayout.PREFERRED_SIZE, 55, javax.swing.GroupLayout.PREFERRED_SIZE)
                            .addGap(15, 15, 15)
                            .addComponent(serialCancelButton))
                        .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, inputSerialDialogLayout.createSequentialGroup()
                            .addComponent(jLabel8)
                            .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                            .addComponent(inputSerialTextField, javax.swing.GroupLayout.PREFERRED_SIZE, 233, javax.swing.GroupLayout.PREFERRED_SIZE))))
                .addContainerGap())
        );
        inputSerialDialogLayout.setVerticalGroup(
            inputSerialDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(inputSerialDialogLayout.createSequentialGroup()
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addComponent(jLabel13)
                .addGap(18, 18, 18)
                .addGroup(inputSerialDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel8)
                    .addComponent(inputSerialTextField, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addGap(18, 18, 18)
                .addGroup(inputSerialDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(serialInputButton)
                    .addComponent(serialCancelButton))
                .addContainerGap())
        );

        editQuantityDialog.setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        editQuantityDialog.setTitle("Edit Product Quantity");
        editQuantityDialog.setBounds(new java.awt.Rectangle(0, 0, 250, 130));
        editQuantityDialog.setModalityType(java.awt.Dialog.ModalityType.APPLICATION_MODAL);
        editQuantityDialog.addWindowListener(new java.awt.event.WindowAdapter() {
            public void windowClosed(java.awt.event.WindowEvent evt) {
                editQuantityDialogWindowClosed(evt);
            }
        });

        editQuantityOK.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        editQuantityOK.setText("OK");
        editQuantityOK.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                editQuantityOKActionPerformed(evt);
            }
        });

        editQuantityCancel.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        editQuantityCancel.setText("Cancel");
        editQuantityCancel.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                editQuantityCancelActionPerformed(evt);
            }
        });

        jLabel9.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jLabel9.setText("Enter quantity:");

        editQuantity.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        editQuantity.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                editQuantityActionPerformed(evt);
            }
        });
        editQuantity.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyPressed(java.awt.event.KeyEvent evt) {
                editQuantityKeyPressed(evt);
            }
        });

        javax.swing.GroupLayout editQuantityDialogLayout = new javax.swing.GroupLayout(editQuantityDialog.getContentPane());
        editQuantityDialog.getContentPane().setLayout(editQuantityDialogLayout);
        editQuantityDialogLayout.setHorizontalGroup(
            editQuantityDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(editQuantityDialogLayout.createSequentialGroup()
                .addGap(29, 29, 29)
                .addGroup(editQuantityDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(editQuantityDialogLayout.createSequentialGroup()
                        .addComponent(jLabel9)
                        .addGap(18, 18, 18)
                        .addComponent(editQuantity, javax.swing.GroupLayout.PREFERRED_SIZE, 54, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, editQuantityDialogLayout.createSequentialGroup()
                        .addComponent(editQuantityOK, javax.swing.GroupLayout.PREFERRED_SIZE, 55, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(editQuantityCancel)))
                .addContainerGap(43, Short.MAX_VALUE))
        );
        editQuantityDialogLayout.setVerticalGroup(
            editQuantityDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(editQuantityDialogLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(editQuantityDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel9)
                    .addComponent(editQuantity, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 43, Short.MAX_VALUE)
                .addGroup(editQuantityDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(editQuantityOK)
                    .addComponent(editQuantityCancel))
                .addContainerGap())
        );

        editSerialDialog.setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        editSerialDialog.setTitle("Edit Product Serial Number");
        editSerialDialog.setBounds(new java.awt.Rectangle(0, 0, 450, 130));
        editSerialDialog.setModalityType(java.awt.Dialog.ModalityType.APPLICATION_MODAL);
        editSerialDialog.addWindowListener(new java.awt.event.WindowAdapter() {
            public void windowClosed(java.awt.event.WindowEvent evt) {
                editSerialDialogWindowClosed(evt);
            }
        });

        editSerialInput.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        editSerialInput.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                editSerialInputActionPerformed(evt);
            }
        });
        editSerialInput.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyPressed(java.awt.event.KeyEvent evt) {
                editSerialInputKeyPressed(evt);
            }
        });

        editSerial.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        editSerial.setText("OK");
        editSerial.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                editSerialActionPerformed(evt);
            }
        });

        cancelEditSerial.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        cancelEditSerial.setText("Cancel");
        cancelEditSerial.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                cancelEditSerialActionPerformed(evt);
            }
        });

        jLabel10.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jLabel10.setText("Enter serial number:");

        javax.swing.GroupLayout editSerialDialogLayout = new javax.swing.GroupLayout(editSerialDialog.getContentPane());
        editSerialDialog.getContentPane().setLayout(editSerialDialogLayout);
        editSerialDialogLayout.setHorizontalGroup(
            editSerialDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(editSerialDialogLayout.createSequentialGroup()
                .addGap(29, 29, 29)
                .addComponent(jLabel10)
                .addGap(26, 26, 26)
                .addComponent(editSerialInput, javax.swing.GroupLayout.PREFERRED_SIZE, 233, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(0, 28, Short.MAX_VALUE))
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, editSerialDialogLayout.createSequentialGroup()
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addComponent(editSerial, javax.swing.GroupLayout.PREFERRED_SIZE, 55, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(cancelEditSerial)
                .addContainerGap())
        );
        editSerialDialogLayout.setVerticalGroup(
            editSerialDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(editSerialDialogLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(editSerialDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel10)
                    .addComponent(editSerialInput, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, 36, Short.MAX_VALUE)
                .addGroup(editSerialDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(editSerial)
                    .addComponent(cancelEditSerial))
                .addContainerGap())
        );

        ReceiptNumber.setTitle("Input Product Receipt Number");
        ReceiptNumber.setBounds(new java.awt.Rectangle(0, 0, 400, 200));
        ReceiptNumber.setModal(true);

        receiptNumberInput.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        receiptNumberInput.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                receiptNumberInputActionPerformed(evt);
            }
        });

        jLabel11.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jLabel11.setText("Receipt Number:");

        jButton3.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jButton3.setText("OK");
        jButton3.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton3ActionPerformed(evt);
            }
        });

        jButton4.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jButton4.setText("Cancel");
        jButton4.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton4ActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout ReceiptNumberLayout = new javax.swing.GroupLayout(ReceiptNumber.getContentPane());
        ReceiptNumber.getContentPane().setLayout(ReceiptNumberLayout);
        ReceiptNumberLayout.setHorizontalGroup(
            ReceiptNumberLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(ReceiptNumberLayout.createSequentialGroup()
                .addGap(44, 44, 44)
                .addComponent(jLabel11)
                .addGap(18, 18, 18)
                .addComponent(receiptNumberInput, javax.swing.GroupLayout.PREFERRED_SIZE, 193, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap(45, Short.MAX_VALUE))
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, ReceiptNumberLayout.createSequentialGroup()
                .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                .addComponent(jButton3)
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                .addComponent(jButton4)
                .addGap(43, 43, 43))
        );
        ReceiptNumberLayout.setVerticalGroup(
            ReceiptNumberLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(ReceiptNumberLayout.createSequentialGroup()
                .addGap(61, 61, 61)
                .addGroup(ReceiptNumberLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(receiptNumberInput, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                    .addComponent(jLabel11))
                .addGap(42, 42, 42)
                .addGroup(ReceiptNumberLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jButton3)
                    .addComponent(jButton4))
                .addContainerGap(140, Short.MAX_VALUE))
        );

        salesHistoryDialog.setTitle("Sales History");
        salesHistoryDialog.setBounds(new java.awt.Rectangle(0, 0, 900, 600));
        salesHistoryDialog.setModalityType(java.awt.Dialog.ModalityType.APPLICATION_MODAL);

        salesHistoryTable.setFont(new java.awt.Font("Tahoma", 0, 12)); // NOI18N
        salesHistoryTable.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "Date", "Product Name", "Quantity", "Receipt Number", "Remarks", "Serial Number", "Type"
            }
        ) {
            boolean[] canEdit = new boolean [] {
                false, false, false, false, false, false, false
            };

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        salesHistoryTable.setRowHeight(20);
        jScrollPane2.setViewportView(salesHistoryTable);

        jLabel15.setFont(new java.awt.Font("Tahoma", 0, 24)); // NOI18N
        jLabel15.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabel15.setText("Sales History");

        jLabel16.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jLabel16.setText("From:");

        jLabel17.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jLabel17.setText("To:");

        dateTo.setWeekStyle(datechooser.view.WeekDaysStyle.FULL);
        dateTo.addSelectionChangedListener(new datechooser.events.SelectionChangedListener() {
            public void onSelectionChange(datechooser.events.SelectionChangedEvent evt) {
                dateToOnSelectionChange(evt);
            }
        });
        dateTo.addCommitListener(new datechooser.events.CommitListener() {
            public void onCommit(datechooser.events.CommitEvent evt) {
                dateToOnCommit(evt);
            }
        });

        dateFrom.setWeekStyle(datechooser.view.WeekDaysStyle.FULL);
        dateFrom.addSelectionChangedListener(new datechooser.events.SelectionChangedListener() {
            public void onSelectionChange(datechooser.events.SelectionChangedEvent evt) {
                dateFromOnSelectionChange(evt);
            }
        });
        dateFrom.addCommitListener(new datechooser.events.CommitListener() {
            public void onCommit(datechooser.events.CommitEvent evt) {
                dateFromOnCommit(evt);
            }
        });

        javax.swing.GroupLayout salesHistoryDialogLayout = new javax.swing.GroupLayout(salesHistoryDialog.getContentPane());
        salesHistoryDialog.getContentPane().setLayout(salesHistoryDialogLayout);
        salesHistoryDialogLayout.setHorizontalGroup(
            salesHistoryDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(salesHistoryDialogLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(salesHistoryDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addComponent(jLabel15, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                    .addGroup(salesHistoryDialogLayout.createSequentialGroup()
                        .addComponent(jLabel16)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(dateFrom, javax.swing.GroupLayout.PREFERRED_SIZE, 182, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(18, 18, 18)
                        .addComponent(jLabel17)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(dateTo, javax.swing.GroupLayout.PREFERRED_SIZE, 182, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(0, 0, Short.MAX_VALUE))
                    .addComponent(jScrollPane2, javax.swing.GroupLayout.DEFAULT_SIZE, 836, Short.MAX_VALUE))
                .addContainerGap())
        );
        salesHistoryDialogLayout.setVerticalGroup(
            salesHistoryDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, salesHistoryDialogLayout.createSequentialGroup()
                .addContainerGap()
                .addComponent(jLabel15)
                .addGap(18, 18, 18)
                .addGroup(salesHistoryDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(salesHistoryDialogLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                        .addComponent(dateTo, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(dateFrom, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addComponent(jLabel17, javax.swing.GroupLayout.Alignment.LEADING))
                    .addComponent(jLabel16, javax.swing.GroupLayout.PREFERRED_SIZE, 17, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addComponent(jScrollPane2, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addContainerGap())
        );

        input.setTitle("Input Length");
        input.setBounds(new java.awt.Rectangle(0, 0, 300, 140));
        input.setModalityType(java.awt.Dialog.ModalityType.APPLICATION_MODAL);

        jLabel18.setText("Please Enter Length of wire");

        jButton6.setText("OK");
        jButton6.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton6ActionPerformed(evt);
            }
        });

        jButton7.setText("Cancel");
        jButton7.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton7ActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout inputLayout = new javax.swing.GroupLayout(input.getContentPane());
        input.getContentPane().setLayout(inputLayout);
        inputLayout.setHorizontalGroup(
            inputLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(inputLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(inputLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addGroup(inputLayout.createSequentialGroup()
                        .addComponent(jButton6)
                        .addGap(18, 18, 18)
                        .addComponent(jButton7))
                    .addGroup(inputLayout.createSequentialGroup()
                        .addComponent(jLabel18)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(inputLength, javax.swing.GroupLayout.PREFERRED_SIZE, 78, javax.swing.GroupLayout.PREFERRED_SIZE)))
                .addGap(170, 170, 170))
        );
        inputLayout.setVerticalGroup(
            inputLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(inputLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(inputLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jLabel18)
                    .addComponent(inputLength, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                .addGroup(inputLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jButton6)
                    .addComponent(jButton7))
                .addContainerGap(108, Short.MAX_VALUE))
        );

        inputWire.setTitle("Wire");
        inputWire.setBounds(new java.awt.Rectangle(0, 0, 200, 165));

        whole.setText("Whole");
        whole.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                wholeActionPerformed(evt);
            }
        });

        partial.setText("Partial");
        partial.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                partialActionPerformed(evt);
            }
        });

        jButton8.setText("OK");
        jButton8.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton8ActionPerformed(evt);
            }
        });

        jButton9.setText("Cancel");
        jButton9.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton9ActionPerformed(evt);
            }
        });

        javax.swing.GroupLayout inputWireLayout = new javax.swing.GroupLayout(inputWire.getContentPane());
        inputWire.getContentPane().setLayout(inputWireLayout);
        inputWireLayout.setHorizontalGroup(
            inputWireLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(inputWireLayout.createSequentialGroup()
                .addContainerGap()
                .addGroup(inputWireLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addGroup(javax.swing.GroupLayout.Alignment.LEADING, inputWireLayout.createSequentialGroup()
                        .addComponent(whole)
                        .addGap(18, 18, 18)
                        .addComponent(partial))
                    .addGroup(inputWireLayout.createSequentialGroup()
                        .addComponent(jButton8, javax.swing.GroupLayout.PREFERRED_SIZE, 64, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(jButton9)))
                .addContainerGap(42, Short.MAX_VALUE))
        );
        inputWireLayout.setVerticalGroup(
            inputWireLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(inputWireLayout.createSequentialGroup()
                .addGap(32, 32, 32)
                .addGroup(inputWireLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(whole)
                    .addComponent(partial))
                .addGap(18, 18, 18)
                .addGroup(inputWireLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                    .addComponent(jButton8)
                    .addComponent(jButton9))
                .addContainerGap(55, Short.MAX_VALUE))
        );

        setBackground(new java.awt.Color(204, 204, 204));
        setCursor(new java.awt.Cursor(java.awt.Cursor.DEFAULT_CURSOR));
        setLayout(new org.netbeans.lib.awtextra.AbsoluteLayout());

        clear.setIcon(new javax.swing.ImageIcon(getClass().getResource("/UI ICONS/xmark.png"))); // NOI18N
        clear.addMouseListener(new java.awt.event.MouseAdapter() {
            public void mouseClicked(java.awt.event.MouseEvent evt) {
                clearMouseClicked(evt);
            }
        });
        add(clear, new org.netbeans.lib.awtextra.AbsoluteConstraints(430, 100, 20, 20));
        clear.setVisible(false);

        inventoryTable.setAutoCreateRowSorter(true);
        inventoryTable.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "product_id", "", "Product Name", "Supplier", "Quantity", "Reorder Quantity Level", "unit"
            }
        ) {
            Class[] types = new Class [] {
                java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.Integer.class, java.lang.String.class, java.lang.Object.class
            };
            boolean[] canEdit = new boolean [] {
                false, false, false, false, false, false, false
            };

            public Class getColumnClass(int columnIndex) {
                return types [columnIndex];
            }

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        inventoryTable.setRowHeight(20);
        inventoryTable.setSelectionForeground(new java.awt.Color(0, 0, 0));
        inventoryTable.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyPressed(java.awt.event.KeyEvent evt) {
                inventoryTableKeyPressed(evt);
            }
        });
        jScrollPane3.setViewportView(inventoryTable);
        if (inventoryTable.getColumnModel().getColumnCount() > 0) {
            inventoryTable.getColumnModel().getColumn(5).setMaxWidth(70);
        }

        add(jScrollPane3, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 134, 530, 480));

        jButton14.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jButton14.setText("Add");
        jButton14.setEnabled(false);
        jButton14.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton14ActionPerformed(evt);
            }
        });
        add(jButton14, new org.netbeans.lib.awtextra.AbsoluteConstraints(410, 620, 130, -1));
        jButton14.getAccessibleContext().setAccessibleName("Add to \\nbought items");
        jButton14.getAccessibleContext().setAccessibleDescription("");

        jButton20.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jButton20.setText("View Critical Products");
        jButton20.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton20ActionPerformed(evt);
            }
        });
        add(jButton20, new org.netbeans.lib.awtextra.AbsoluteConstraints(730, 10, 180, -1));

        jLabel2.setFont(new java.awt.Font("Tahoma", 0, 24)); // NOI18N
        jLabel2.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
        jLabel2.setText("Product Inventory");
        add(jLabel2, new org.netbeans.lib.awtextra.AbsoluteConstraints(0, 10, 1100, -1));

        jButton1.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jButton1.setText("Search");
        jButton1.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton1ActionPerformed(evt);
            }
        });
        add(jButton1, new org.netbeans.lib.awtextra.AbsoluteConstraints(460, 100, -1, -1));

        inventoryTableSearchInput.setFont(new java.awt.Font("Tahoma", 0, 16)); // NOI18N
        inventoryTableSearchInput.addKeyListener(new java.awt.event.KeyAdapter() {
            public void keyPressed(java.awt.event.KeyEvent evt) {
                inventoryTableSearchInputKeyPressed(evt);
            }
        });
        add(inventoryTableSearchInput, new org.netbeans.lib.awtextra.AbsoluteConstraints(300, 100, 150, -1));

        cartTable.setAutoCreateRowSorter(true);
        cartTable.setModel(new javax.swing.table.DefaultTableModel(
            new Object [][] {

            },
            new String [] {
                "Product_id", "Warranty", "Name", "Supplier", "Physical Count", "Purchase Type", "Serial No.", "Quantity", "wire"
            }
        ) {
            Class[] types = new Class [] {
                java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.String.class, java.lang.Integer.class, java.lang.Object.class, java.lang.String.class, java.lang.Integer.class, java.lang.Object.class
            };
            boolean[] canEdit = new boolean [] {
                false, false, false, false, false, true, false, false, false
            };

            public Class getColumnClass(int columnIndex) {
                return types [columnIndex];
            }

            public boolean isCellEditable(int rowIndex, int columnIndex) {
                return canEdit [columnIndex];
            }
        });
        cartTable.setRowHeight(20);
        jScrollPane4.setViewportView(cartTable);
        if (cartTable.getColumnModel().getColumnCount() > 0) {
            cartTable.getColumnModel().getColumn(3).setResizable(false);
            cartTable.getColumnModel().getColumn(4).setMaxWidth(70);
            cartTable.getColumnModel().getColumn(7).setMaxWidth(70);
        }

        add(jScrollPane4, new org.netbeans.lib.awtextra.AbsoluteConstraints(558, 134, 520, 400));

        jButton2.setFont(new java.awt.Font("Tahoma", 1, 14)); // NOI18N
        jButton2.setText("Checkout");
        jButton2.setEnabled(false);
        jButton2.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton2ActionPerformed(evt);
            }
        });
        add(jButton2, new org.netbeans.lib.awtextra.AbsoluteConstraints(980, 620, -1, -1));

        jLabel1.setFont(new java.awt.Font("Tahoma", 0, 16)); // NOI18N
        jLabel1.setText("Products selected");
        add(jLabel1, new org.netbeans.lib.awtextra.AbsoluteConstraints(560, 100, -1, -1));

        jLabel3.setFont(new java.awt.Font("Tahoma", 0, 16)); // NOI18N
        jLabel3.setText("Date:");
        add(jLabel3, new org.netbeans.lib.awtextra.AbsoluteConstraints(560, 50, -1, -1));

        removeFromListButton.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        removeFromListButton.setText("Delete");
        removeFromListButton.setEnabled(false);
        removeFromListButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                removeFromListButtonActionPerformed(evt);
            }
        });
        add(removeFromListButton, new org.netbeans.lib.awtextra.AbsoluteConstraints(900, 90, 80, 30));

        productFilterCategoryComboBox.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        productFilterCategoryComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
        productFilterCategoryComboBox.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                productFilterCategoryComboBoxActionPerformed(evt);
            }
        });
        add(productFilterCategoryComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(80, 40, 210, -1));

        jLabel7.setFont(new java.awt.Font("Tahoma", 0, 16)); // NOI18N
        jLabel7.setText("Category:");
        add(jLabel7, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 40, 70, -1));

        jLabel5.setFont(new java.awt.Font("Tahoma", 0, 16)); // NOI18N
        jLabel5.setText("Supplier:");
        add(jLabel5, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 70, -1, 23));

        productFilterSupplierComboBox.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        productFilterSupplierComboBox.setModel(new javax.swing.DefaultComboBoxModel(new String[] { "Item 1", "Item 2", "Item 3", "Item 4" }));
        productFilterSupplierComboBox.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                productFilterSupplierComboBoxActionPerformed(evt);
            }
        });
        add(productFilterSupplierComboBox, new org.netbeans.lib.awtextra.AbsoluteConstraints(80, 70, 210, -1));

        editButton.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        editButton.setText("Edit Quantity/Serial");
        editButton.setEnabled(false);
        editButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                editButtonActionPerformed(evt);
            }
        });
        add(editButton, new org.netbeans.lib.awtextra.AbsoluteConstraints(700, 90, 180, 30));

        salesDateChooser.setNothingAllowed(false);
        salesDateChooser.setWeekStyle(datechooser.view.WeekDaysStyle.FULL);
        salesDateChooser.setFieldFont(new java.awt.Font("Tahoma", java.awt.Font.PLAIN, 14));
        add(salesDateChooser, new org.netbeans.lib.awtextra.AbsoluteConstraints(610, 50, 260, -1));

        clearTableButton.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        clearTableButton.setText("Clear All");
        clearTableButton.setEnabled(false);
        clearTableButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                clearTableButtonActionPerformed(evt);
            }
        });
        add(clearTableButton, new org.netbeans.lib.awtextra.AbsoluteConstraints(990, 90, 90, 30));

        jLabel4.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jLabel4.setText("Receipt No :");
        add(jLabel4, new org.netbeans.lib.awtextra.AbsoluteConstraints(560, 620, -1, -1));

        receiptNos.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        receiptNos.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                receiptNosActionPerformed(evt);
            }
        });
        add(receiptNos, new org.netbeans.lib.awtextra.AbsoluteConstraints(640, 620, 290, -1));

        jLabel12.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jLabel12.setText("Remarks :");
        add(jLabel12, new org.netbeans.lib.awtextra.AbsoluteConstraints(560, 540, -1, -1));

        remarksInput.setColumns(20);
        remarksInput.setRows(5);
        jScrollPane1.setViewportView(remarksInput);

        add(jScrollPane1, new org.netbeans.lib.awtextra.AbsoluteConstraints(560, 560, 520, 50));

        jSeparator1.setOrientation(javax.swing.SwingConstants.VERTICAL);
        add(jSeparator1, new org.netbeans.lib.awtextra.AbsoluteConstraints(550, 40, 20, 640));

        jButton5.setFont(new java.awt.Font("Tahoma", 0, 14)); // NOI18N
        jButton5.setText("View Sales History");
        jButton5.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                jButton5ActionPerformed(evt);
            }
        });
        add(jButton5, new org.netbeans.lib.awtextra.AbsoluteConstraints(930, 10, -1, -1));

        jLabel14.setFont(new java.awt.Font("Tahoma", 0, 16)); // NOI18N
        jLabel14.setText("Current Inventory");
        add(jLabel14, new org.netbeans.lib.awtextra.AbsoluteConstraints(10, 110, -1, -1));
    }// </editor-fold>//GEN-END:initComponents

    private void jButton14ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton14ActionPerformed
        cartController.addToCart();
        InputValidator.enabler2(cartTable, jButton2);
        InputValidator.enabler2(cartTable, clearTableButton);
    }//GEN-LAST:event_jButton14ActionPerformed

    private void jButton20ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton20ActionPerformed
        criticalProducts.setVisible(true);
    }//GEN-LAST:event_jButton20ActionPerformed

    private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton1ActionPerformed
        cartController.searchProduct();
    }//GEN-LAST:event_jButton1ActionPerformed

    private void jButton2ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton2ActionPerformed
        cartController.markItemsAsSold();
    }//GEN-LAST:event_jButton2ActionPerformed

    private void clearMouseClicked(java.awt.event.MouseEvent evt) {//GEN-FIRST:event_clearMouseClicked
        cartController.clearSearch();
        InputValidator.enabler2(cartTable, jButton2);
        InputValidator.enabler2(cartTable, clearTableButton);
    }//GEN-LAST:event_clearMouseClicked

    private void selectPurchaseButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_selectPurchaseButtonActionPerformed

    }//GEN-LAST:event_selectPurchaseButtonActionPerformed

    private void selectServiceButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_selectServiceButtonActionPerformed

    }//GEN-LAST:event_selectServiceButtonActionPerformed

    private void cancelButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_cancelButtonActionPerformed
        cartController.closeSalesTypeDialog();
    }//GEN-LAST:event_cancelButtonActionPerformed

    private void removeFromListButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_removeFromListButtonActionPerformed
        cartController.removeSelectedRow();
        InputValidator.enabler2(cartTable, jButton2);
        InputValidator.enabler2(cartTable, clearTableButton);
    }//GEN-LAST:event_removeFromListButtonActionPerformed

    private void productFilterCategoryComboBoxActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_productFilterCategoryComboBoxActionPerformed
        cartController.filterProducts();
    }//GEN-LAST:event_productFilterCategoryComboBoxActionPerformed

    private void productFilterSupplierComboBoxActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_productFilterSupplierComboBoxActionPerformed
        cartController.filterProducts();
    }//GEN-LAST:event_productFilterSupplierComboBoxActionPerformed

    private void editButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_editButtonActionPerformed
        cartController.editDialog();
        InputValidator.enabler2(cartTable, jButton2);
        InputValidator.enabler2(cartTable, clearTableButton);
    }//GEN-LAST:event_editButtonActionPerformed

    private void inputQuantityTextFieldActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_inputQuantityTextFieldActionPerformed
        // TODO add your handling code here:
    }//GEN-LAST:event_inputQuantityTextFieldActionPerformed
    
    private void quantityCancelButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_quantityCancelButtonActionPerformed
        inputQuantityTextField.setText("");
        quantityInputDialog.dispose();
    }//GEN-LAST:event_quantityCancelButtonActionPerformed

    private void quantityInputButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_quantityInputButtonActionPerformed
        cartController.inputQuantityDialog();
        inputQuantityTextField.setText("");
        InputValidator.enabler2(cartTable, jButton2);
        InputValidator.enabler2(cartTable, clearTableButton);
    }//GEN-LAST:event_quantityInputButtonActionPerformed

    private void inputSerialTextFieldActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_inputSerialTextFieldActionPerformed
        
    }//GEN-LAST:event_inputSerialTextFieldActionPerformed

    private void serialInputButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_serialInputButtonActionPerformed
        cartController.inputSerialDialog();
        inputSerialTextField.setText("");
        InputValidator.enabler2(cartTable, jButton2);
        InputValidator.enabler2(cartTable, clearTableButton);
    }//GEN-LAST:event_serialInputButtonActionPerformed

    private void serialCancelButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_serialCancelButtonActionPerformed
        inputSerialTextField.setText("");
        inputSerialDialog.dispose();
    }//GEN-LAST:event_serialCancelButtonActionPerformed

    private void inventoryTableSearchInputKeyPressed(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_inventoryTableSearchInputKeyPressed
        if (evt.getKeyCode()== KeyEvent.VK_ENTER)
	{
            jButton1.doClick();
	}
    }//GEN-LAST:event_inventoryTableSearchInputKeyPressed

    private void inputQuantityTextFieldKeyPressed(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_inputQuantityTextFieldKeyPressed
        if (evt.getKeyCode()== KeyEvent.VK_ENTER)
	{
            quantityInputButton.doClick();
            inputQuantityTextField.setText("");
	}
    }//GEN-LAST:event_inputQuantityTextFieldKeyPressed

    private void inputSerialTextFieldKeyPressed(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_inputSerialTextFieldKeyPressed
        if (evt.getKeyCode()== KeyEvent.VK_ENTER)
	{
            serialInputButton.doClick();
            inputSerialTextField.setText("");
	}
    }//GEN-LAST:event_inputSerialTextFieldKeyPressed

    private void clearTableButtonActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_clearTableButtonActionPerformed
        cartController.clearList();
    }//GEN-LAST:event_clearTableButtonActionPerformed

    private void editQuantityOKActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_editQuantityOKActionPerformed
        cartController.editQuantityDialog();
    }//GEN-LAST:event_editQuantityOKActionPerformed

    private void editQuantityCancelActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_editQuantityCancelActionPerformed
        editQuantityDialog.dispose();
        editQuantity.setText("");
    }//GEN-LAST:event_editQuantityCancelActionPerformed

    private void editQuantityActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_editQuantityActionPerformed
        // TODO add your handling code here:
    }//GEN-LAST:event_editQuantityActionPerformed

    private void editQuantityKeyPressed(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_editQuantityKeyPressed
        if (evt.getKeyCode()== KeyEvent.VK_ENTER){
            editQuantityOK.doClick();
            editQuantity.setText("");
        }
    }//GEN-LAST:event_editQuantityKeyPressed

    private void editSerialInputActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_editSerialInputActionPerformed
        // TODO add your handling code here:
    }//GEN-LAST:event_editSerialInputActionPerformed

    private void editSerialInputKeyPressed(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_editSerialInputKeyPressed
        if (evt.getKeyCode()==KeyEvent.VK_ENTER){
            cartController.editSerialDialog();
            editSerialInput.setText("");
        }
    }//GEN-LAST:event_editSerialInputKeyPressed

    private void editSerialActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_editSerialActionPerformed
        cartController.editSerialDialog();
    }//GEN-LAST:event_editSerialActionPerformed

    private void cancelEditSerialActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_cancelEditSerialActionPerformed
        editSerialDialog.dispose();
        editSerialInput.setText("");
    }//GEN-LAST:event_cancelEditSerialActionPerformed

    private void inventoryTableKeyPressed(java.awt.event.KeyEvent evt) {//GEN-FIRST:event_inventoryTableKeyPressed
        if (evt.getKeyCode()==KeyEvent.VK_ENTER){
            cartController.addToCart();
            InputValidator.enabler2(cartTable, jButton2);
            InputValidator.enabler2(cartTable, clearTableButton);
        }
        
    }//GEN-LAST:event_inventoryTableKeyPressed

    private void jButton3ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton3ActionPerformed
       cartController.markItemsAsSold();
    }//GEN-LAST:event_jButton3ActionPerformed

    private void receiptNumberInputActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_receiptNumberInputActionPerformed
        // TODO add your handling code here:
    }//GEN-LAST:event_receiptNumberInputActionPerformed

    private void receiptNosActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_receiptNosActionPerformed
        // TODO add your handling code here:
    }//GEN-LAST:event_receiptNosActionPerformed

    private void jButton4ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton4ActionPerformed
        ReceiptNumber.dispose();
        receiptNumberInput.setText("");
    }//GEN-LAST:event_jButton4ActionPerformed

    private void quantityInputDialogWindowClosed(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_quantityInputDialogWindowClosed
        inputQuantityTextField.setText("");
    }//GEN-LAST:event_quantityInputDialogWindowClosed

    private void inputSerialDialogWindowClosed(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_inputSerialDialogWindowClosed
        inputSerialTextField.setText("");
    }//GEN-LAST:event_inputSerialDialogWindowClosed

    private void editQuantityDialogWindowClosed(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_editQuantityDialogWindowClosed
        editQuantity.setText("");
    }//GEN-LAST:event_editQuantityDialogWindowClosed

    private void editSerialDialogWindowClosed(java.awt.event.WindowEvent evt) {//GEN-FIRST:event_editSerialDialogWindowClosed
        editSerialInput.setText("");
    }//GEN-LAST:event_editSerialDialogWindowClosed

    private void jButton5ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton5ActionPerformed
        cartController.updateSalesHistory();
        salesHistoryDialog.setVisible(true);
    }//GEN-LAST:event_jButton5ActionPerformed

    private void dateFromOnSelectionChange(datechooser.events.SelectionChangedEvent evt) {//GEN-FIRST:event_dateFromOnSelectionChange
        cartController.updateSalesHistory();
    }//GEN-LAST:event_dateFromOnSelectionChange

    private void dateToOnSelectionChange(datechooser.events.SelectionChangedEvent evt) {//GEN-FIRST:event_dateToOnSelectionChange
        cartController.updateSalesHistory();
    }//GEN-LAST:event_dateToOnSelectionChange

    private void dateFromOnCommit(datechooser.events.CommitEvent evt) {//GEN-FIRST:event_dateFromOnCommit
        cartController.updateSalesHistory();
    }//GEN-LAST:event_dateFromOnCommit

    private void dateToOnCommit(datechooser.events.CommitEvent evt) {//GEN-FIRST:event_dateToOnCommit
        cartController.updateSalesHistory();
    }//GEN-LAST:event_dateToOnCommit

    private void jButton6ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton6ActionPerformed
        cartController.addRollToCart();
        InputValidator.enabler2(cartTable, jButton2);
        InputValidator.enabler2(cartTable, clearTableButton);
    }//GEN-LAST:event_jButton6ActionPerformed

    private void jButton7ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton7ActionPerformed
        input.dispose();
    }//GEN-LAST:event_jButton7ActionPerformed

    private void jButton9ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton9ActionPerformed
        inputWire.dispose();
    }//GEN-LAST:event_jButton9ActionPerformed

    private void jButton8ActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_jButton8ActionPerformed
        cartController.addRoll();
    }//GEN-LAST:event_jButton8ActionPerformed

    private void wholeActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_wholeActionPerformed
        partial.setSelected(false);
    }//GEN-LAST:event_wholeActionPerformed

    private void partialActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_partialActionPerformed
        whole.setSelected(false);
    }//GEN-LAST:event_partialActionPerformed
    
    public static JTable getInventoryTable(){
        return inventoryTable;
    }
    
    public static JComboBox<ComboItem> getProductFilterCategoryComboBox(){
        return productFilterCategoryComboBox;
    }
    
    public static JComboBox<ComboItem> getProductFilterSupplierComboBox(){
        return productFilterSupplierComboBox;
    }
    
    public static void updateSalesHistory(){
        cartController.updateSalesHistory();
    }
    
    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JDialog ReceiptNumber;
    private javax.swing.JButton cancelButton;
    private javax.swing.JButton cancelEditSerial;
    private static javax.swing.JTable cartTable;
    private javax.swing.JLabel clear;
    private javax.swing.JButton clearTableButton;
    private datechooser.beans.DateChooserCombo dateFrom;
    private datechooser.beans.DateChooserCombo dateTo;
    private javax.swing.JButton editButton;
    private javax.swing.JTextField editQuantity;
    private javax.swing.JButton editQuantityCancel;
    private javax.swing.JDialog editQuantityDialog;
    private javax.swing.JButton editQuantityOK;
    private javax.swing.JButton editSerial;
    private javax.swing.JDialog editSerialDialog;
    private javax.swing.JTextField editSerialInput;
    private javax.swing.JDialog input;
    private javax.swing.JTextField inputLength;
    private javax.swing.JTextField inputQuantityTextField;
    private javax.swing.JDialog inputSerialDialog;
    private javax.swing.JTextField inputSerialTextField;
    private javax.swing.JDialog inputWire;
    private static javax.swing.JTable inventoryTable;
    private javax.swing.JTextField inventoryTableSearchInput;
    private javax.swing.JButton jButton1;
    private javax.swing.JButton jButton14;
    private javax.swing.JButton jButton2;
    private javax.swing.JButton jButton20;
    private javax.swing.JButton jButton3;
    private javax.swing.JButton jButton4;
    private javax.swing.JButton jButton5;
    private javax.swing.JButton jButton6;
    private javax.swing.JButton jButton7;
    private javax.swing.JButton jButton8;
    private javax.swing.JButton jButton9;
    private javax.swing.JLabel jLabel1;
    private javax.swing.JLabel jLabel10;
    private javax.swing.JLabel jLabel11;
    private javax.swing.JLabel jLabel12;
    private javax.swing.JLabel jLabel13;
    private javax.swing.JLabel jLabel14;
    private javax.swing.JLabel jLabel15;
    private javax.swing.JLabel jLabel16;
    private javax.swing.JLabel jLabel17;
    private javax.swing.JLabel jLabel18;
    private javax.swing.JLabel jLabel2;
    private javax.swing.JLabel jLabel3;
    private javax.swing.JLabel jLabel4;
    private javax.swing.JLabel jLabel5;
    private javax.swing.JLabel jLabel6;
    private javax.swing.JLabel jLabel7;
    private javax.swing.JLabel jLabel8;
    private javax.swing.JLabel jLabel9;
    private javax.swing.JScrollPane jScrollPane1;
    private javax.swing.JScrollPane jScrollPane2;
    private javax.swing.JScrollPane jScrollPane3;
    private javax.swing.JScrollPane jScrollPane4;
    private javax.swing.JSeparator jSeparator1;
    private javax.swing.JRadioButton partial;
    private static javax.swing.JComboBox<ComboItem> productFilterCategoryComboBox;
    private static javax.swing.JComboBox<ComboItem> productFilterSupplierComboBox;
    private javax.swing.JButton quantityCancelButton;
    private javax.swing.JButton quantityInputButton;
    private javax.swing.JDialog quantityInputDialog;
    private javax.swing.JLabel receiptInfoLabel1;
    private javax.swing.JLabel receiptInfoLabel2;
    private javax.swing.JTextField receiptNos;
    private javax.swing.JTextField receiptNumberInput;
    private javax.swing.JTextArea remarksInput;
    private javax.swing.JButton removeFromListButton;
    private datechooser.beans.DateChooserCombo salesDateChooser;
    private javax.swing.JDialog salesHistoryDialog;
    private javax.swing.JTable salesHistoryTable;
    private javax.swing.JDialog salesTypeDialog;
    private javax.swing.JButton selectPurchaseButton;
    private javax.swing.JButton selectServiceButton;
    private javax.swing.JButton serialCancelButton;
    private javax.swing.JButton serialInputButton;
    private javax.swing.JRadioButton whole;
    // End of variables declaration//GEN-END:variables
}
